﻿using Luna小店.UC.面料库存.面料出库.service;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Luna小店.UC.面料库存.面料出库.model
{
    public class StockOutModel
    {
        /// <summary>
        /// 数据清洗，计算调整值
        /// </summary>
        public DTO订单领料出库明细总览 DTO订单领料出库明细总览 { get; set; }
        public StockOutModel build(DTO订单领料出库明细总览 DTO订单领料出库明细总览) {
            this.DTO订单领料出库明细总览 = DTO订单领料出库明细总览;
            foreach (DTO订单领料出库单 DTO订单领料出库单 in this.DTO订单领料出库明细总览.orderDetails)
            {
                if (this.DTO订单领料出库明细总览.stringListMap.ContainsKey(DTO订单领料出库单.orderId))
                {
                    DTO订单领料出库单.异常调整 = this.DTO订单领料出库明细总览.stringListMap[DTO订单领料出库单.orderId];
                    DTO订单领料出库单.build计算调整值();
                }
            }
            return this;
        }
    }
}
